home *** CD-ROM | disk | FTP | other *** search
/ Atari Mega Archive 1 / Atari Mega Archive - Volume 1.iso / graphics / pbm / pbm_man.zoo / man1 / pnmrotate.1 < prev    next >
Text File  |  1994-08-27  |  2KB  |  67 lines

  1.  
  2.  
  3.  
  4. pnmrotate(1)             USER COMMANDS               pnmrotate(1)
  5.  
  6.  
  7.  
  8. NAME
  9.      pnmrotate - rotate a portable anymap by some angle
  10.  
  11. SYNOPSIS
  12.      pnmrotate [-noantialias] _✓a_✓n_✓g_✓l_✓e [_✓p_✓n_✓m_✓f_✓i_✓l_✓e]
  13.  
  14. DESCRIPTION
  15.      Reads a portable anymap as input.  Rotates it by the  speci-
  16.      fied angle and produces a portable anymap as output.  If the
  17.      input file is in color, the output will be too, otherwise it
  18.      will  be  grayscale.   The  angle  is  in  degrees (floating
  19.      point), measured counter-clockwise.  It can be negative, but
  20.      it  should  be  between  -90  and  90.   Also, for rotations
  21.      greater than 45 degrees you may get better  results  if  you
  22.      first use _✓p_✓n_✓m_✓f_✓l_✓i_✓p to do a 90 degree rotation and then _✓p_✓n_✓m_✓r_✓o_✓-
  23.      _✓t_✓a_✓t_✓e less than 45 degrees back the other direction
  24.  
  25.      The rotation algorithm is Alan Paeth's  three-shear  method.
  26.      Each  shear is implemented by looping over the source pixels
  27.      and distributing fractions to each of the  destination  pix-
  28.      els.   This has an "anti-aliasing" effect - it avoids jagged
  29.      edges and similar artifacts.  However, it  also  means  that
  30.      the  original  colors  or gray levels in the image are modi-
  31.      fied.  If you need to keep precisely the same set of colors,
  32.      you  can  use the -noantialias flag.  This does the shearing
  33.      by moving pixels without changing their values.  If you want
  34.      anti-aliasing  and  don't care about the precise colors, but
  35.      still need a limited *number* of colors,  you  can  run  the
  36.      result through _✓p_✓p_✓m_✓q_✓u_✓a_✓n_✓t.
  37.  
  38.      All flags can be abbreviated to their shortest  unique  pre-
  39.      fix.
  40.  
  41. REFERENCES
  42.      "A Fast Algorithm  for  General  Raster  Rotation"  by  Alan
  43.      Paeth, Graphics Interface '86, pp. 77-81.
  44.  
  45. SEE ALSO
  46.      pnmshear(1), pnmflip(1), pnm(5), ppmquant(1)
  47.  
  48. AUTHOR
  49.      Copyright (C) 1989, 1991 by Jef Poskanzer.
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63. Sun Release 4.0   Last change: 12 January 1991                  1
  64.  
  65.  
  66.  
  67.